<?php
/*
	插件概览
*/
defined('BY_JYA') or exit('error');
$_RQ['op']=$_RQ['op']?$_RQ['op']:'get';
if($_RQ['op']=='upworker'){
	$app_id=$_SESSION['wxworkapp_id']=$_RQ['app_id'];
	$_SESSION['onemerchid']=pdo_getcolumn('core_account_wxwork_app',array('id'=>$app_id,'uniacid'=>$_SESSION['uniacid']),'merchid');
	$user_ticket=model('core/wxwork_userapi')->get_worker_user_ticket($_RQ['code']);
	$info=model('core/wxwork_userapi')->get_worker_info($user_ticket);
	model('jy_scrm/worker')->upinfo($info);
	exi('同步员工信息成功！','','/index/');
}